export function getDuration(from : string, to : string) {
	var key = "Y7PBZ-OKFWQ-53C5B-BX5XN-P4KSJ-VMBHE"
	return new Promise((resolve, reject) => {
		uni.request({
			url: `https://apis.map.qq.com/ws/direction/v1/driving/?from=${from}&to=${to}&output=json&callback=cb&key=${key}`,
			method: "GET",
			success: (res : any) => {
				resolve(res)
			},
			fail: (err : any) => {
				reject(err)
			}
		});
	})
}